<template>
  <div class="logo">
    <router-link to="/">
      <img :src="baseUrl+logo">
      <span> {{ name }}</span>
    </router-link>>
  </div>
</template>

<script>
import { mapState } from 'vuex'
export default {
  data () {
    return {
      baseUrl: process.env.BASE_URL
    }
  },
  computed: {
    ...mapState({
      name: state => state.app.name,
      logo: state => state.app.logo
    })
  }
}
</script>

<style lang="scss" scoped>
.logo{
  height: 64px;
  line-height: 64px;
  padding-left: 24px;
  transition: all .3s;
  background: #002140;
  overflow: hidden;
  img{
    width: 32px;
    height: 32px;
  }
  span{
    color: #fff;
    display: inline-block;
    vertical-align: middle;
    font-size: 20px;
    margin: 0 0 0 30px;
    font-weight: 600;
  }
}
</style>
